{{if false}}<script>{{/if}}
{{$controller = $smarty.const.CCTRL}}
{{$token = $smarty.const.TOKEN}}
{{include file="../00_base/function.tpl"}}
function handleEvents(){
    try{
        myGrid.bind('cellselect', function (event) {
            var _dataRow=myGrid.jqxGrid('getrowdata', event.args.rowindex);
            var _id=_dataRow._id==undefined?(_dataRow.ID==undefined?_dataRow.ProductID:_dataRow.ID):_dataRow._id;
            if(_id!=undefined){
                $("#_logs").html(
                    "<table>\
                        <tr><td class='w100px'>Time</td><td>"+_dataRow.Insert+"</td></tr>\
                        <tr><td>Full Name</td><td>"+_dataRow.FullName+"</td></tr>\
                        <tr><td>Email    </td><td>"+_dataRow.Email+"</td></tr>\
                        <tr><td>Phone    </td><td>"+_dataRow.Phone+"</td></tr>\
                        <tr><td>Subject    </td><td>"+_dataRow.Subject+"</td></tr>\
                        <tr><td class='vtat'>Message    </td><td><pre>"+_dataRow.Message+"</pre></td></tr>\
                    </table>"
                );
            }else{
                $("#_logs").html("");
            }
        });
    }catch(e){uiMessage(e.message);}
}